//
//  DaysGoalSetupWeekCollectionCell.swift
//  DaRings
//
//  Created by 魔样科技 on 2022/11/11.
//

import Foundation
import MYModule
import UIKit

class GoalSetupWeekDaysCollectionCell: CollectionViewCell {
    
    override func makeUI() {
        super.makeUI()
        
        self.contentView.addSubview(self.titleLabel)
        self.titleLabel.snp.makeConstraints { make in
            make.edges.equalToSuperview()
        }
    }
    
    func bindModel(model: GoalSetupWeekDayModel) {
        self.titleLabel.text = model.title
        self.titleLabel.backgroundColor = model.isSelected ? UIColor.theme : UIColor.assist_D0D0D0
    }
    
    //MARK: - lazy load -
    private lazy var titleLabel: Label = {
        let label = Label()
        label.textColor = .assist_FFFFFF
        label.font = Fonts.systemFont(ofSize: 14)
        label.setFastCorners(6)
        label.backgroundColor = .assist_D0D0D0
        label.textAlignment = .center
        return label
    }()
}
